
html
    head
        title= title
        meta(charset='UTF-8')
        meta(http-equiv='X-UA-Compatible', content='IE=edge')
        meta(name='viewport', content='width=device-width, initial-scale=1')
        link(rel='SHORTCUT ICON', href='favicon1.ico', type='image/x-icon')
        link(rel='stylesheet', href='/lib/bootstrap3/css/bootstrap.min.css')
        link(rel='stylesheet', href='/stylesheets/style.css')
        script(src='/lib/jquery-1.11.0.js')
        script(src='/lib/bootstrap3/js/bootstrap.min.js')
        script(src='/js/script.js')
    body.login-bg
    div.login-con
        div.ivu-card
            div.ivu-card-head 欢迎登录
            div.ivu-card-body
                div.form-con
                    form
                        div.ivu-form-item
                            div.ivu-form-item-content
                                div.ivu-input-group
                                    div.ivu-input-group-prepend
                                        span
                                            i.glyphicon.glyphicon-user(style="font-size: 12px;")
                                    input.ivu-input(id='loginname', name='loginname', type='text', placeholder='用户名')
                        div.ivu-form-item
                            div.ivu-form-item-content
                                div.ivu-input-group
                                    div.ivu-input-group-prepend
                                        span
                                            i.glyphicon.glyphicon-lock(style="font-size: 12px;")
                                    input.ivu-input(id='password', name='password', type='password', placeholder="密码")
                                div.error
                        div.ivu-form-item
                            button.ivu-btn.ivu-btn-primary.ivu-btn-long#loginBtn= '登录'

                    p.login-tip 请输入用户名和密码
    //
    //script.
    //    $(function () {
    //        $('#loginBtn').click(function () {
    //            var loginname = $('#loginname').val();
    //            var password = $('#password').val();
    //            var html ='';
    //            html +='<div class="login-error-message"> '+ "请输入用户名或密码" + '</div>'
    //            if (!loginname || !password) {
    //                alert("请输入用户名和密码")
    //            } else {
    //                $.post('/login', {
    //                    loginname: loginname,
    //                    password: password
    //                }, function (result) {
    //                    console.log(result);
    //                    if (result.errcode === 0) {
    //                        location.href = '/index';
    //                    } else {
    //                    }
    //                });
    //            }
    //
    //
    //        });
    //    });



